package com.zgxt.demo.util;


import com.zgxt.demo.Dao.UserDao;

public class UserHolder {
    private static final ThreadLocal<UserDao> userHolder = new ThreadLocal<>();

    public static void setUserDao(UserDao userDao) {
        userHolder.set(userDao);
    }
    public static UserDao getUserDao() {
        return userHolder.get();
    }

    public static void removeUserDao() {
        userHolder.remove();
    }
}
